//
//  DetailDynTableViewCell.m
//  ChatDemo-UI2.0
//
//  Created by zz on 16/3/17.
//  Copyright © 2016年 zz. All rights reserved.
//

#import "DetailDynTableViewCell.h"

@implementation DetailDynTableViewCell

-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        
        CGFloat x = 20;
        CGFloat top = 15;
        CGFloat w = 300;
        CGFloat h = 20;
        
        for (int i = 0; i < 4; i++) {
            
         CGFloat  y = top + (h + 5) * i;
            
            UILabel *label = [[UILabel alloc] init];
            label.frame = CGRectMake(x, y , w, h);
            label.textColor=RGBACOLOR(85, 85, 85, 1);
            label.font=[UIFont systemFontOfSize:16];
            [self.contentView addSubview:label];
            
            switch (i) {
                case 0:
                    _classLabel = label;
                    break;
                case 1:
                    _subLabel = label;
                    break;
                case 2:
                    _timeLabel = label;
                    break;
                default:
                    _nameLabel = label;
                    break;
            }
        }

    }
    
    return self;
}

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
